package com.university.vo;

import java.sql.Timestamp;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 * Settle entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "settle", catalog = "university")

public class Settle implements java.io.Serializable {

	// Fields

	private Integer settleId;
	private Student student;
	private String settleUnit;
	private Integer settleTimesCount;
	private Boolean settleIsClose;
	private Integer settlePartTimeId;
	private Double settleMoney;
	private Timestamp settleEndTime;
	private Timestamp settleBeginTime;
	private String settleInfo;

	// Constructors

	/** default constructor */
	public Settle() {
	}

	@Override
	public String toString() {
		return "Settle [settleId=" + settleId + ", student=" + student + ", settleUnit=" + settleUnit
				+ ", settleTimesCount=" + settleTimesCount + ", settleIsClose=" + settleIsClose + ", settlePartTimeId="
				+ settlePartTimeId + ", settleMoney=" + settleMoney + ", settleEndTime=" + settleEndTime
				+ ", settleBeginTime=" + settleBeginTime + ", settleInfo=" + settleInfo + "]";
	}

	/** full constructor */
	public Settle(Student student, String settleUnit, Integer settleTimesCount, Boolean settleIsClose,
			Integer settlePartTimeId, Double settleMoney, Timestamp settleEndTime, Timestamp settleBeginTime,
			String settleInfo) {
		this.student = student;
		this.settleUnit = settleUnit;
		this.settleTimesCount = settleTimesCount;
		this.settleIsClose = settleIsClose;
		this.settlePartTimeId = settlePartTimeId;
		this.settleMoney = settleMoney;
		this.settleEndTime = settleEndTime;
		this.settleBeginTime = settleBeginTime;
		this.settleInfo = settleInfo;
	}

	// Property accessors
	@Id
	@GeneratedValue

	@Column(name = "settle-Id", unique = true, nullable = false)

	public Integer getSettleId() {
		return this.settleId;
	}

	public void setSettleId(Integer settleId) {
		this.settleId = settleId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "settle_studentId")

	public Student getStudent() {
		return this.student;
	}

	public void setStudent(Student student) {
		this.student = student;
	}

	@Column(name = "settle_unit", length = 10)

	public String getSettleUnit() {
		return this.settleUnit;
	}

	public void setSettleUnit(String settleUnit) {
		this.settleUnit = settleUnit;
	}

	@Column(name = "settle_timesCount")

	public Integer getSettleTimesCount() {
		return this.settleTimesCount;
	}

	public void setSettleTimesCount(Integer settleTimesCount) {
		this.settleTimesCount = settleTimesCount;
	}

	@Column(name = "settle_isClose", insertable = false)

	public Boolean getSettleIsClose() {
		return this.settleIsClose;
	}

	public void setSettleIsClose(Boolean settleIsClose) {
		this.settleIsClose = settleIsClose;
	}

	@Column(name = "settle_partTimeId")

	public Integer getSettlePartTimeId() {
		return this.settlePartTimeId;
	}

	public void setSettlePartTimeId(Integer settlePartTimeId) {
		this.settlePartTimeId = settlePartTimeId;
	}

	@Column(name = "settle_money", precision = 22, scale = 0)

	public Double getSettleMoney() {
		return this.settleMoney;
	}

	public void setSettleMoney(Double settleMoney) {
		this.settleMoney = settleMoney;
	}

	@Column(name = "settle_endTime", length = 19)

	public Timestamp getSettleEndTime() {
		return this.settleEndTime;
	}

	public void setSettleEndTime(Timestamp settleEndTime) {
		this.settleEndTime = settleEndTime;
	}

	@Column(name = "settle_beginTime", length = 19)

	public Timestamp getSettleBeginTime() {
		return this.settleBeginTime;
	}

	public void setSettleBeginTime(Timestamp settleBeginTime) {
		this.settleBeginTime = settleBeginTime;
	}

	@Column(name = "settle_info", length = 200)

	public String getSettleInfo() {
		return this.settleInfo;
	}

	public void setSettleInfo(String settleInfo) {
		this.settleInfo = settleInfo;
	}

}